package com.leadership.entity.actionlearning;

import com.demo2do.core.utils.Alias;

/**
 * 刻意练习行动计划表状态
 * 
 * @author mohanlan
 *
 */
@Alias("actionLearningStatus")
public enum Status {
    
    STASH("stash", "编辑中", false, "编辑中"),
    
    CREATED("created", "未开始", true, "未开始"),
    
    PROCESSING("processing", "进行中", true, "进行中"),
    
    FINISHED("finished", "已完成", true, "已完成"),
    
    EXPIRY("expiry", "已逾期", true, "已逾期");
    
    private String alias;
    
    private String description;
    
    private boolean showClient;
    
    private String clientDesc;
    
    /**
     * 
     * @param alias
     * @param description
     */
    private Status(String alias, String description, boolean showClient, String clientDesc) {
        this.alias = alias;
        this.description = description;
        this.showClient = showClient;
        this.clientDesc = clientDesc;
    }
    
    /**
     * 
     * @param alias
     * @return
     */
    public static Status aliasOf(String alias) {
        
        for(Status status : Status.values()) {
            if(status.getAlias().equals(alias)) {
                
                return status;
            }
        }
        return null;
    }
    
    public String getAlias() {
        return alias;
    }
    
    public String getDescription() {
        return description;
    }
    
    public boolean isShowClient() {
        return showClient;
    }
    
    public String getClientDesc() {
        return clientDesc;
    }
}
